// Copyright 2022 a.o.smith ALL Rights Reserved
package com.liuxinlong.enums;

/**
 * 培训文档类型枚举
 *
 * @author liuxinlong@hotwater.com.cn
 * @version 1.0.0
 * @since 2023-02-09
 */
public enum ButlerContentTypeEnum {
    DOCUMENT(0, "文档"),
    VIDEO(1, "视频"),
    OUT_URL(2, "外部链接"),
    INNER_URL(3, "内部链接");

    private int value;

    private String name;

    ButlerContentTypeEnum(int value, String name) {
        this.value = value;
        this.name = name;
    }

    public int getValue() {
        return value;
    }

    public String getName() {
        return name;
    }

    public static String getNameByValue(int value) {
        ButlerContentTypeEnum arrObj[] = ButlerContentTypeEnum.values();
        for (ButlerContentTypeEnum obj : arrObj) {
            if (value == obj.getValue()) {
                return obj.getName();
            }
        }
        return " ";
    }

}
